/*
 * ChooseDeliveryListItem.java
 * business
 *
 * Created by ChenTao on 2017/2/14.
 *
 * Copyright (c) 2017年 yidiandao. All rights reserved.
 */

package com.yidiandao.business.ui.widget.listview.displaylistitem;

import android.content.Context;

import com.yidiandao.business.data.response.GetShippingWayListResponse;
import com.yidiandao.business.ui.widget.listview.DisplayListItem;
import com.yidiandao.business.ui.widget.listview.viewholder.ChooseShippingWayHolder;

/**
 * 确认订单-选择配送方式-ListItem
 *
 * <p>Created by ChenTao(chentao7v@gmail.com) on 2017/2/14 10:27
 */
public class ChooseShippingWayListItem
        extends DisplayListItem<
        ChooseShippingWayHolder, GetShippingWayListResponse.ShippingWayInfo> {

    public ChooseShippingWayListItem(GetShippingWayListResponse.ShippingWayInfo s) {
        super(s);
    }

    @Override
    public void onShow(Context context, ChooseShippingWayHolder holder) {
        holder.refreshTitle(data.getSupplierName());
        holder.refreshShippingWays(data.getShippingWayList());
        holder.refreshUIImages(data.getGoodsThumbs());
    }

    @Override
    public String getDisplayItemTag() {
        return ChooseShippingWayListItem.class.getSimpleName();
    }

    @Override
    public Class<ChooseShippingWayHolder> getViewHolderClazz() {
        return ChooseShippingWayHolder.class;
    }
}
